package com.mes.dao.yzl;

import com.mes.entity.hpf.SaleOutDetail;
import com.mes.entity.hpf.SalePlanDetail;
import com.mes.entity.yzl.Condition;
import com.mes.entity.yzl.OutLib;
import com.mes.entity.yzl.ProContactOrder;
import com.mes.entity.yzlExtend.ExtendOutlib;
import com.mes.entity.yzlExtend.ExtendProductor;

import java.util.List;

import org.apache.ibatis.annotations.Param;

public interface OutlibMapper {
    int checkNumUnique(String returnNumber);

    long addOutOrder(OutLib outLib);

    void addCentor(ProContactOrder proContactOrder);

    int countOutlibCount(Condition condition);

    List<ExtendOutlib> listOutlibList(Condition condition);

    List<ExtendProductor> outOrderXq(long id);

    ExtendOutlib findOutorderById(long id);

    long updateOutLib(OutLib outLib);

    void updateCentorOutLib(ProContactOrder proContactOrder);

    List<OutLib> outLibList();
    
    int deleteOutLibOrder(long id);
    
    int outlibApproveds(List<Integer> list);
    
    int outlibUnApproveds(List<Integer> list);
    
    List<ExtendProductor> outLibXq(long id);
    
    void deleteLibXq(long outLibId);
    
    int libOutbound(List<Integer> list);
    
    int cusOrderbound(List<Integer> list);
    
    int cusOrderboundTwo(List<Integer> list);
    
    int cusOrderCount(Condition condition);
    
    List<ExtendProductor> cusOrderList(Condition condition);
    
    void setSelectCusOrder(@Param("pid")long pid,@Param("type")int type);
    
    List<ExtendProductor> addCusOrderXq(long id);
    
    ProContactOrder findCusCenterProByPid(long pid);
    
    List<ExtendProductor> customerOrderXq(long id);
    
    int planDetailCount(Condition condition);
    
    List<SalePlanDetail> planDetailList(Condition condition);
    
    void addOutDetail(SaleOutDetail saleOutDetail);
    
    void updatePlanDetailStatus(SalePlanDetail salePlanDetail);
    
    List<SaleOutDetail> outDetail(long id);
    
    void updateOutDetail(SaleOutDetail saleOutDetail);
    
    void deleteOutDetail(long id);
    
    void setSelectPlanDetail(SalePlanDetail salePlanDetail);
    
    SalePlanDetail findPlanDetailById(long id);
}
